<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
    <%@ include file="datalink.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-utf-8">
<title>check</title>
</head>
<body>
<form method="post" action="">
<% 
   String name=request.getParameter("id");
   String password=request.getParameter("password");
if(name.equals("root")&&password.equals("root"))
{   
    Statement sd = null;
    sd = conn.createStatement();
    String time="2021-11-26";
    String sql="INSERT INTO loginma(id,time) VALUES('"+name+"','"+time+"')";
    sd.execute(sql);
    response.sendRedirect("choose.jsp");}
else
response.sendRedirect("loginfailure.jsp");
%>
</form>
</div>
</body>
</html>
